﻿
 
 
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
 
<title>jb-aptech毕业设计项目</TITLE>
<meta name="renderer" content="ie-comp">
 
<link href="../../css/style.css" rel="stylesheet" type="text/css">
<script src="script/common.js"></script>
<script src="script/validate.js"></script>
		<link rel="stylesheet" type="text/css" href="ExtJS/resources/css/ext-all.css">
<script type="text/javascript" src="ExtJS/adapter/ext/ext-base.js"></script>
<script type="text/javascript" src="ExtJS/ext-all.js"></script>
</head>
  	<script type="text/javascript">
  		
  		function mySearch(){
  				var arrName=new Array();
				arrName[0]="usrName";
				checkWay(arrName);
  			document.sysUserForm.submit();
  		}
  	</script>
  <body>
  <div id="app">
    <div class="page_title">权限管理 > 用户管理 > 系统用户管理</div>
    <form name="sysUserForm" method="post" action="/CRM/sysUser.do">
    <input type="hidden" name="method" value="userForward">
    	<div class="button_bar">
	   		<button class="common_button" onclick="help('');">帮助</button>
	   		<button class="common_button" onclick="to('sysUser.do?method=toAddUser');">新建</button>
			<button class="common_button" onclick="mySearch();">查询</button>
	   	</div>
	   	<table class="query_form_table">
	   		<tr>
	   			<th>
	   				用户名
	   			</th>
	   			<td>
	   				<input type="text" name="sysUser.usrName" size="20" value="" id="usrName">
	   			</td>
	   			<th>
	   				是否禁用
	   			</th>
	   			<td>
	   				<select name="sysUser.usrFlag" id="usrFlag"><option value="-1">全部</option>
	   					<option value="1">正常</option>
	   					<option value="2">禁用</option></select>
	   			</td>
	   		</tr>
	   	</table>
	   	<br/>
	   	<table class="data_list_table">
	   		<tr>
	   			<th>编号</th>
	   			<th>用户名</th>
	   			<th>角色</th>
	   			<th>状态</th>
	   			<th>操作</th>
	   		</tr>
 
	   		
	   		<tr v-for="i in page.records">
	   			<td class="list_data_text">{{i.usrId}}</td>
	   			<td class="list_data_text">{{i.usrName}}</td>
	   			<td class="list_data_text">{{i.sysRole.roleName}}</td>
	   			<td class="list_data_text">
	   				
	   					正常
	   				
	   				
	   			</td>
	   			<td class="list_data_op">
	   				
	   					<img onclick="to('sysUser.do?method=toEditUser&userId=2')" title="编辑" src="images/bt_edit.gif" class="op_button" />
	   					<img onclick="to('sysUser.do?method=toDispatchList&userId=2');" title="指派" src="images/bt_linkman.gif" class="op_button" />
	   				
	   				<img onclick="to('sysUser.do?method=toDetail&userId=2');" title="查看" src="images/bt_deal.gif" class="op_button" />
	   				
	   					<img onclick="mydel('sysUser.do?method=toDelete&userId=2');" title="删除" src="images/bt_del.gif" class="op_button" />
	   				
	   			</td>
	   		</tr>
	   		

	   		
	   		<tr>
		<th colspan="7" class="pager">
<div>
	每页{{page.size}}条记录&nbsp;共{{page.total}}条记录&nbsp;&nbsp;第1页&nbsp;&nbsp;共2页&nbsp;&nbsp;
	<a disabled>首页</a>
	<a  disabled>上一页</a>
	<a  href="javaScript:window.location='?curpage=2&pageNum=5&method=userForward'">下一页</a>
	<a href="javaScript:window.location='?curpage=2&pageNum=5&method=userForward'">尾页</a>&nbsp;&nbsp;&nbsp;&nbsp;转到：
	<select id='_gotoPageCount' onchange="window.location='?curpage='+this.value+'&pageNum=5&method=userForward'">
	<option  selected  value=1 >第1页</option>
	<option  value=2 >第2页</option>
</select>&nbsp;&nbsp;&nbsp;&nbsp;
	<select onchange="window.location='?pageNum='+this.value+'&method=userForward'">
<option  value=6 >每页6条记录</option>
<option  value=12 >每页12条记录</option>
<option  value=18 >每页18条记录</option>
<option  value=24 >每页24条记录</option>
<option  value=30 >每页30条记录</option>
</select>
</div>
		</th>
	</tr>
	   	</table>
    </form>

</div>
<script src="../../../js/vue2.js"></script>
<script src="../../../js/axios.min.js"></script>
<script>
	const vue = new Vue({
		el:'#app',
		data:{
			page:{
				records:[],//数据
				total:0,//总记录数
				size:5,//每页条数
				current:1//当前页
			}
		},
		methods:{
			getPage(){
				axios.post("/SysUser/Page",this.page).then(res=>{
					this.page = res.data;
				});
			}
		},
		created(){
			this.getPage();
		}
	});
</script>
  </body>
</html>
